package _0util;

import java.util.UUID;

/**
 * @ClassName RandomUtil
 * @Description: 随机数生成
 * @Author wangzhen
 * @Date 2020/3/13
 **/
public class RandomUtil {

    /**
     * 生成随机字母+数字,默认36位
     * @return
     */
    public static String getRandomStr(){

        UUID uuid = UUID.randomUUID();
        String[] split = uuid.toString().split("-");
        StringBuilder sb=new StringBuilder(36);
        for(String item:split){
            sb.append(item);
        }

        return sb.toString();
    }
}
